#region File Header
//----------------------------------------------------------------
// Copyright (C) 2002 Stefan Kyntchev
// All rights reserved.
//
// THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY 
// OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT 
// LIMITED TO THE IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR 
// FITNESS FOR A PARTICULAR PURPOSE.
//----------------------------------------------------------------
#endregion File Header

namespace AirWeb.WebControls.TreeControl
{
    using System;
	using System.Web.UI;
    using System.Web.UI.WebControls;

    /// <summary>
    ///    Node item is used to generate a representation of a tree node. By overriding the
    ///    Render method subclasses can create custom node rendering. Nodes must be rendered by
    ///    using WebControl derived classes by inserting them to i_context collection
    /// </summary>
    public abstract class NodeItem
    {
		/// <summary>
		/// Tree node instance that owns that node item. 
		/// </summary>
		protected TreeNode m_Owner;

		public abstract void Render(ControlCollection i_context);

		/// <summary>
		/// Tree node instance that owns this node item
		/// </summary>
		public TreeNode Owner
		{
			get
			{
				return m_Owner;
			}
			set
			{
				m_Owner = value;
			}
		}
	}
}
